#include "my_head.h"

bool show_information(p_user_node head,int *b,char *p)
{
    if(head==NULL)
    {
        printf("error\n");
        return false;
    }
    p_user_node x=head->next;
    while(x!=NULL&&(*b!=x->data.user_account.id||strcmp(p,x->data.user_account.password)!=0))
    {
        x=x->next;
    }
    if(x!=NULL)
    {
        printf("用户角色为:%s\n",x->data.user_role);
        printf("用户的用户名为:%s\n",x->data.user_name);
        printf("用户账号为:%d\n",x->data.user_account.id);
        printf("用户密码为:%s\n",x->data.user_account.password);
        printf("用户权限为:%d\n",x->data.user_account.permission);
        printf("=============\n");
        return true;
    }
}